import 'dart:convert';

class QABanner {
  String id, imgTarget, imgResUrl;

  QABanner(this.id, this.imgTarget, this.imgResUrl);

  factory QABanner.fromJson(Map<String, dynamic> data) {
    return QABanner(
      data["id"],
      data["imgTarget"],
      data["imgResUrl"],
    );
  }

  Map<String, dynamic> toJson() {
    return {
      "id": id,
      "imgTarget": imgTarget,
      "imgResUrl": imgResUrl,
    };
  }

  @override
  String toString() {
    return json.encode(toJson());
  }
}
